package org.gfix.annotation;

import java.lang.annotation.Documented;

import org.gfix.types.FixVersion;

/**
 * This annotation provides binding of a specific message
 * to a specific class type.
 * Normally this would be a combination of tag 35 and other 
 * non group member fields.
 * @author alan
 *
 */
@Documented
public @interface FixMessageBinding {
	
	public enum MatchType{REGULAR_EXP, EQUALS};
	
	/**
	 * The version of FIX that this binding is applicable for.
	 * 
	 * @return
	 */
	public FixVersion fixVersion();
	
	/**
	 * The tag, this fields value is bound to
	 * @return
	 */
	public int fixTag();
	
	/**
	 * The value in the tag that this class matches
	 * This will be treated as a regular expression
	 * @return
	 */
	public String matches();
	
	public MatchType matchType() default MatchType.EQUALS;
	
	/**
	 * The value for the given tag when converting the class to FIX
	 * 
	 * @return
	 */
	public String sending();
	
}
